﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="Module_TopNews.ascx.cs"
    Inherits="Modules_Module_TopNews" %>
<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" 
    DataSourceID="SqlDataSource1" BorderStyle="None" CellPadding="0" GridLines ="None">
    <Columns>
        <asp:TemplateField>
        <HeaderStyle CssClass="hidden" />
            <ItemTemplate>
                <a href='./news_view.aspx?id=<%# Eval("id") %>' target="_self">
                    <%# Eval("title") %></a><br />
            </ItemTemplate>
        </asp:TemplateField>
    </Columns>
</asp:GridView>
<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:allshareConnectionString3 %>"
    ProviderName="<%$ ConnectionStrings:allshareConnectionString3.ProviderName %>"
    SelectCommand="SELECT * FROM news WHERE isTop=1 AND enable=1 ORDER BY publishtime DESC LIMIT 3">
</asp:SqlDataSource>
